
<form class="well form-horizontal span8" action="<?php echo base_url() . "index.php/titulo/actualizar" ?>" method="post">
    <legend>MODIFICAR DATOS DE TITULOS ALCANZADOS</legend>
    <?php foreach ($titulo as $i => $row) { ?>

        <div class="control-group">
            <label class="control-label" for="select03">DOCENTE</label>
            <div class="controls ">
                <select name="ide_doc" class="span3">
                    <?php
                    foreach ($docente as $i => $doc) {
                        echo ("<option value='" . $doc["ide_doc"] . "'" );
                        echo ($row["ide_doc"] == $ide_doc ? ' selected > ' : ' > ');
                        echo ($doc["apellido_pers"] . " " . $doc["nombre_pers"] . "</option>");
                    }
                    ?>
                </select>
                <?php if (isset($msj_error)) { ?>
                    <div class='MensajeError'>
                        <?php echo ($msj_error); ?>
                    </div>
                <?php } ?>

            </div>
        </div>

        <div class="control-group">
            <label class="control-label" for="select03">Nivel del T&iacute;tulo</label>
            <div class="controls ">
                <select id="select01"  name="nivel_tit" class="span3">
                    <option value="0"<?php echo ($row["nivel_tit"] == 0 ? ' selected ' : '  ' ); ?>>NINGUNO</option>
                    <option value="1"<?php echo ($row["nivel_tit"] == 1 ? ' selected ' : '  ' ); ?>>TECNICO SUPERIOR</option>
                    <option value="2"<?php echo ($row["nivel_tit"] == 2 ? ' selected ' : '  ' ); ?>>TECNOLOGICO SUPERIOR</option>
                    <option value="3"<?php echo ($row["nivel_tit"] == 3 ? ' selected ' : '  ' ); ?>>TERCER NIVEL</option>
                    <option value="4"<?php echo ($row["nivel_tit"] == 4 ? ' selected ' : '  ' ); ?>>DOCTOR EN FILOSOFIA</option>
                    <option value="5"<?php echo ($row["nivel_tit"] == 5 ? ' selected ' : '  ' ); ?>>DIPLOMADO SUPERIOR</option>
                    <option value="6"<?php echo ($row["nivel_tit"] == 6 ? ' selected ' : '  ' ); ?>>ESPECIALISTA</option>
                    <option value="7"<?php echo ($row["nivel_tit"] == 7 ? ' selected ' : '  ' ); ?>>MAGISTER</option>
                    <option value="8"<?php echo ($row["nivel_tit"] == 8 ? ' selected ' : '  ' ); ?>>DOCTOR Ph. D</option>

                </select>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label" for="input03">Denominaci&oacute;n del T&iacute;tulo</label>
            <div class="controls">
                <input type="text" class="input-medium span4"  name="denom_tit" value="<?php echo $row["denom_tit"]; ?>">
                <li class="icon-asterisk"></li>
                <div class='MensajeError'>
                    <?php echo form_error('denom_tit') ?>
                </div>

            </div>
        </div>
        <div class="control-group">
            <label class="control-label" for="input04">Fecha del T&iacute;tulo </label>
            <div class="controls">
                <input type="text" class="input-medium"  id="datepicker1" name="Fecha_tit" value="<?php echo date("m/d/Y", strtotime($row["Fecha_tit"])); ?>">
                <li class="icon-asterisk"></li>
                <div class='MensajeError'>
                    <?php echo form_error('Fecha_tit') ?>
                </div>

            </div>
        </div>

        <div class="control-group">
            <label class="control-label" for="input05">Instituci&oacute;n que lo otorga</label>
            <div class="controls">
                <input type="text" class="input-medium span4"  name="ies_otorga_tit" value="<?php echo $row["ies_otorga_tit"]; ?>">
                <li class="icon-asterisk"></li>
                <div class='MensajeError'>
                    <?php echo form_error('ies_otorga_tit') ?>
                </div>

            </div>
        </div>
        <div class="control-group">
            <label class="control-label" for="input07">Pa&iacute;s</label>
            <div class="controls">
                <input type="text" class="input-medium span3"  name="pais_tit" value="<?php echo $row["pais_tit"]; ?>">
                <li class="icon-asterisk"></li>
                <div class='MensajeError'>
                    <?php echo form_error('pais_tit') ?>
                </div>

            </div>
        </div>
        <div class="control-group">
            <label class="control-label" for="input08">Registro Senecyt</label>
            <div class="controls">
                <input type="text" class="input-medium span3"  name="reg_tit" value="<?php echo $row["reg_tit"]; ?>">
                <li class="icon-asterisk"></li>
                <div class='MensajeError'>
                    <?php echo form_error('reg_tit') ?>
                </div>

            </div>
        </div>

        <fieldset>
            <div class="control-group"> 
                <div class="controls">
                    <input type="hidden" name="ide_doc" value="<?php echo $ide_doc; ?>">
                    <input type="hidden" name="ide_tit" value="<?php echo $row["ide_tit"]; ?>">
                    <input type="hidden"  name="txtopc" value="<?php echo $opc; ?>">

                </div>
            </div >
        </fieldset>

    <?php } ?>

    <div class="controls">
        <?php if ($opc == 'upd') { ?>
            <button type="submit" class="btn">Modificar Datos</button>

        <?php } else { ?>
            <button type="submit" class="btn">Eliminar Datos</button>
        <?php } ?>
        <a href="<?php echo base_url() . "index.php/titulo/inicio" ?>">
            <img src="<?php echo base_url(); ?>commons/images/boton_volver.gif"></a>

    </div> 


</form>

